package org.jeecg.modules.demo.com.kunpeng.service;

import com.baomidou.mybatisplus.extension.plugins.pagination.Page;
import org.jeecg.modules.demo.com.kunpeng.entity.OaStorehouseDetail;
import org.jeecg.modules.demo.com.kunpeng.entity.OaStorehouseInfo;
import com.baomidou.mybatisplus.extension.service.IService;
import org.jeecg.modules.demo.com.kunpeng.vo.OaStorehouseDetailQueryListVO;

import java.io.Serializable;
import java.util.Collection;
import java.util.List;

/**
 * @Description: 仓库表
 * @Author: jeecg-boot
 * @Date:   2023-02-28
 * @Version: V1.0
 */
public interface IOaStorehouseInfoService extends IService<OaStorehouseInfo> {

	/**
	 * 添加一对多
	 *
	 * @param oaStorehouseInfo
	 * @param oaStorehouseDetailList
	 */
	public void saveMain(OaStorehouseInfo oaStorehouseInfo,List<OaStorehouseDetail> oaStorehouseDetailList) ;
	
	/**
	 * 修改一对多
	 *
   * @param oaStorehouseInfo
   * @param oaStorehouseDetailList
	 */
	public void updateMain(OaStorehouseInfo oaStorehouseInfo,List<OaStorehouseDetail> oaStorehouseDetailList);
	
	/**
	 * 删除一对多
	 *
	 * @param id
	 */
	public void delMain (String id);
	
	/**
	 * 批量删除一对多
	 *
	 * @param idList
	 */
	public void delBatchMain (Collection<? extends Serializable> idList);

	/**
	 * 根据id 修改仓库状态值
	 * @param id
	 */
	String updateStorehouseStateById(String id);

	/**
	 * 根据仓库名称模糊查询
	 */
	Page<OaStorehouseDetailQueryListVO> oaStorehouseInfoListByName(Page<OaStorehouseInfo>page, String name);
}
